<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width,initial-scale=1">
    <?php include_once MvcReg::$_moduleName . '/views/layout/head.php'; ?>

</head>
<body>
<?php include_once MvcReg::$_moduleName . '/views/layout/header.php'; ?>
<?php include_once MvcReg::$_moduleName . '/views/layout/top-nav.php'; ?>
<div id="main">
    <div class="container-fluid">
        <div class="row">
            <div class="col-md-2">
                <?php include_once MvcReg::$_moduleName . '/views/layout/left_menu.php'; ?>
            </div>
            <div class="col-md-12">
                <div class="right-content">
                    <h3>
                        <?php echo $menu["breadcrumb_current"] ?>
                    </h3>
                    <br>
                    <form name="mainform" action="" method="get">
                        <?php echo $hidden_data ?>
                        <div class="table-responsive">
                            <div class="panel panel-default">
                                <div class="panel-body form-inline">
                                    <div class="form-group">
                                        <label>收货人手机号:</label>
                                        <input type="text" name="q_mobile"
                                               value="<?php echo $q_mobile ?>"
                                               class="form-control input-sm" placeholder=""/>
                                    </div>
                                    <div class="form-group">
                                        <label>预计送达时间:</label>
                                        <div class="input-group">
                                            <span class="input-group-addon">
                                                <span class="glyphicon glyphicon-calendar">
                                                </span>
                                            </span>
                                            <input size="16" type="text" name="q_from_date" readonly=""
                                                   class="form_datetime form-control"
                                                   value="<?php echo $q_from_date ?>">
                                            <span class="input-group-addon">
                                                至
                                            </span>
                                            <input size="16" type="text" name="q_to_date" readonly=""
                                                   class="form_datetime form-control" value="<?php echo $q_to_date ?>">
                                        </div>
                                    </div>
                                    <div class="form-group">
                                        <label>配货单号:</label>
                                        <input type="text" name="q_phno"
                                               value="<?php echo $q_phno ?>"
                                               class="form-control input-sm" placeholder=""/>
                                    </div>
                                    <button type="submit" class="btn btn-primary"><span
                                                class="glyphicon glyphicon-search"></span>立即查询
                                    </button>
                                </div>
                            </div>
                            <table class="table table-hover">
                                <thead>
                                <tr class="info">
                                    <th>序</th>
                                    <th class="col-md-4">配送信息</th>
                                    <th class="col-md-5">订单信息</th>
                                    <th>操作区</th>
                                </tr>
                                </thead>
                                <tbody>
                                <?php
                                if($rsp_list){
                                $n = 0;
                                foreach ($rsp_list as $k => $row) {
                                    $n++;
                                    $item = $n + ($page - 1) * $number_page;
                                    $id = $row["id"];
                                    ?>
                                    <tr data-id="<?php echo $id ?>" id="<?php echo $id ?>">
                                        <td><?php echo $item ?></td>
                                        <?php include MvcReg::$_moduleName . '/views/layout/orderlist_td.php'; ?>
                                        <input type="hidden" id="expid" value="<?php echo $row['exp_id']?>">

                                        <td>
                                            <div>
                                                <?php if($row['exp_shop_remark']){
                                                    $status = '已处理';
                                                }else{
                                                    $status = '未处理';
                                                }?>
                                                <button type="button" class="btn btn-primary showError" data-toggle="modal" data-target="#error_remarks" code="<?php echo $row['exp_id'];?>" id=" <?php echo $row['exp_error_remark'] ?>-<?php echo $row['exp_shop_remark'] ?>-<?php echo $row['exp_is_visible'] ?>"><?php echo $status?></button>
                                            </div>

                                            <div style="margin-top: 10px;">
                                                <button type="button" class="btn btn-primary"
                                                        onclick="OrderDetails('<?php echo $id ?>')">
                                                    查看订单详情
                                                </button>
                                            </div>
                                        </td>
                                    </tr>
                                <?php }
                                }
                                ?>
                                </tbody>
                            </table>
                            <div class="page">
                                <div class="pagination pull-left">共<?php echo $total_count ?>笔记录</div>
                                <?php if (!empty($rsp_page_list)) echo $rsp_page_list; ?>
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>


<?php include_once MvcReg::$_moduleName . '/views/layout/footer.php'; ?>
<?php include_once MvcReg::$_moduleName . '/views/dialog/express_order_error_remarks.php'; ?>

<script>

</script>
</body>
</html>
